Fix compilation in C90 mode (#284)
authorThomas Koutcher <thomas.koutcher@online.fr>
Fri, 20 Jun 2025 20:10:58 +0000 (22:10 +0200)
committerGitHub <noreply@github.com>
Fri, 20 Jun 2025 20:10:58 +0000 (16:10 -0400)
utf8proc.c

index 34619947eca05e356fc9202785e4ca1b1618a644..a7aff86e923b9675172f2475d4cd3f69368ca327 100644 (file)
@@ -688,8 +688,9 @@ UTF8PROC_DLLEXPORT utf8proc_ssize_t utf8proc_normalize_utf32(utf8proc_int32_t *b
           int len = starter_property->comb_length;
           utf8proc_int32_t max_second = utf8proc_combinations_second[idx + len - 1];
           if (current_char <= max_second) {
+            int off;
             // TODO: binary search? arithmetic search?
-            for (int off = 0; off < len; ++off) {
+            for (off = 0; off < len; ++off) {
               utf8proc_int32_t second = utf8proc_combinations_second[idx + off];
               if (current_char < second) {
                 /* not found */